module.exports = Behavior({
    data: {
        orderStatusList: [ {
            label: "待付款",
            value: 10
        }, {
            label: "申请发货",
            value: 20
        }, {
            label: "待发货",
            value: 30
        }, {
            label: "待收货",
            value: 40
        }, {
            label: "已完成",
            value: 50
        }, {
            label: "已关闭",
            value: 70
        }, {
            label: "已取消",
            value: 0
        } ],
        robotOrderStatusList: [ {
            label: "待付款",
            value: 10
        }, {
            label: "待出货",
            value: 20
        }, {
            label: "已完成",
            value: 50
        }, {
            label: "已关闭",
            value: 70
        }, {
            label: "已取消",
            value: 0
        } ],
        shopOrderStatusList: [ {
            label: "待付款",
            value: 0
        }, {
            label: "已关闭",
            value: 1
        }, {
            label: "待出货",
            value: 2
        }, {
            label: "已完成",
            value: 3
        }, {
            label: "已关闭",
            value: 4
        }, {
            label: "退款中",
            value: 5
        } ]
    },
    attached: function() {},
    methods: {
        getOrderStatusTitle: function(e) {
            var l = this.data.orderStatusList.find(function(l) {
                return l.value == e;
            });
            return l ? l.label : "";
        },
        getRobotOrderStatusTitle: function(e) {
            var l = this.data.robotOrderStatusList.find(function(l) {
                return l.value == e;
            });
            return l ? l.label : "";
        },
        getShopOrderStatusTitle: function(e) {
            var l = this.data.shopOrderStatusList.find(function(l) {
                return l.value == e;
            });
            return l ? l.label : "";
        }
    }
});